<template>
  <div id="self">
    <van-nav-bar title="我的资料" />
    <ul class="pTop">
      <li>
        <b>头像</b>
        <div>
          <img src="../../assets/img/2.jpg" />
          <van-icon class="arrow" name="arrow" />
        </div>
      </li>
      <li>
        <b>身份认证</b><span>张三<van-icon class="arrow" name="arrow" /></span>
      </li>
      <li>
        <b>会员名称</b><span>李四<van-icon class="arrow" name="arrow" /></span>
      </li>
      <li>
        <b>性别</b><span>男<van-icon class="arrow" name="arrow" /></span>
      </li>
    </ul>
    <ul class="pBom">
      <li>
        <b>手机号码</b
        ><span>123*****789<van-icon class="arrow" name="arrow" /></span>
      </li>
      <li><b>修改支付密码</b><van-icon class="arrow" name="arrow" /></li>
      <li><b>修改登录密码</b><van-icon class="arrow" name="arrow" /></li>
    </ul>
    <nav @click="removeToken">退出登录</nav>
  </div>
</template>

<script>
export default {
  methods: {
    removeToken() {
      sessionStorage.removeItem("token"); 
      this.$router.push({ path: "/User" });
    },
  },
};
</script>

<style lang="scss" scoped>
#self {
  background: #ddd;
}
ul {
  margin-bottom: 20px;
  box-sizing: border-box;
  padding-left: 10px;
}
li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  div {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  b {
    height: 21px;
    color: rgba(0, 0, 0, 1);
    font-size: 14px;
    line-height: 150%;
    text-align: left;
    font-weight: bold;
  }
  span {
    height: 21px;

    color: rgba(80, 80, 80, 1);
    font-size: 14px;
    line-height: 150%;
    text-align: left;
  }
}
.pTop {
  width: 375px;
  height: 185px;
  color: rgba(80, 80, 80, 1);
  background-color: rgba(255, 255, 255, 1);
  font-size: 14px;
  line-height: 150%;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  li {
    img {
      width: 40px;
      height: 40px;
      border-radius: 75px;
    }
  }
}
.pBom {
  width: 375px;
  height: 126px;
  color: rgba(80, 80, 80, 1);
  background-color: rgba(255, 255, 255, 1);
  border-radius: 8px;
  font-size: 14px;
  line-height: 150%;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
}
nav {
  width: 375px;
  height: 48px;
  color: rgba(80, 80, 80, 1);
  background-color: rgba(255, 255, 255, 1);
  border-radius: 8px;
  font-size: 14px;
  line-height: 48px;
  text-align: center;
  font-weight: bold;
}
.arrow {
  width: 26px;
  height: 26px;
  text-align: left;
  font-size: 100%;
  color: rgba(153, 153, 153, 1);
}
</style>